/**
 * @Author: ycq_work@163.com
 * @DATE: 2023/7/16
 * @Description: 
*/
#ifndef CONLOGIN_H
#define LOGIN_H

#include <QWidget>
#include <QString>
#include <QDebug>

#include "../Controller/ConLogin.h"
#include "mainwindow.h"

QT_BEGIN_NAMESPACE
namespace Ui
{
class Login;
}
QT_END_NAMESPACE

class Login: public QWidget
{
Q_OBJECT
private:
    QString account;
    QString password;
    contr::ConLogin login;

public:
    [[nodiscard]] const QString &getAccount() const;
    [[nodiscard]] const QString &getPassword() const;

public:
    explicit Login(QWidget *parent = nullptr);
    ~Login() override;

private slots:
    void on_accountEdit_textChanged(const QString &_account);
    void on_pswEdit_textChanged(const QString &pwd);

    void on_loginBtn_clicked();
    void on_cancelBtn_clicked();

private:
    Ui::Login *ui;
};


#endif //CONLOGIN_H
